import numpy as np
import matplotlib.pyplot as plt
from math import ceil, floor, sqrt

'''
host throughput and bisection bandwidth
'''
threshold = 100000
linewidth = 1
markersize = 4
plt.figure(1)


througput = []
with open( "K8_S100_L10_a1.0_out.txt", 'r') as f:
    for line in f.readlines():
    	split = line.split()
        print split
        througput.append(float(split[3]))   
througput.sort()
cdfx2 = througput
cdfy2 = np.linspace(1 / len(througput), 1.0, len(througput))
plt.plot(cdfx2, cdfy2,'r', linewidth=1, markersize=4, label='OSA')
plt.show()